import Vue from 'vue'

export function httpErrMsg (response, baseText = '') {
  const res = response || {}
  const message = res._errStr || baseText

  if (res._errCode === '200000') return

  if (import.meta.env.HSB_PROJECT_PLATFORM === 'pc') {
    return Vue.prototype.$message.error(message)
  }
  Vue.prototype.$vant.Toast(message)
}